package visitor;

import Arbori.Nod;
import FunctiiElementare.Constanta;
import FunctiiElementare.Necunoscuta;
import FunctiiTrigo.Cos;
import FunctiiTrigo.Sin;
import Operatori.Cat;
import Operatori.Minus;
import Operatori.Plus;
import Operatori.Produs;

public class ToStringVisitor extends Visitor{
	String s;

	public void visit(Plus p) {
		if(p.getFStang()!=null && p.getFDrept()!=null)
		{
			visit (p.getFStang());
			String s1=this.s;
			visit(p.getFDrept());
			String s2=this.s;
			s=p.concatTermeni(s1, s2);
		}
		
	}


	public void visit(Minus m) {

		
	}


	public void visit(Cat m) {

		
	}


	public void visit(Produs p) {

		
	}


	public void visit(Necunoscuta n) {

		
	}


	public void visit(Constanta c) {

		
	}


	public void visit(Sin s) {

		
	}


	public void visit(Cos c) {
		
		
	}

	
	public void visit(Nod n) {
		
		
	}

}
